-- GENERATED SPELL FOR [Ghostly Raider] --


function spell0_11686(pUnit, Event) --@Concussive Shot,n/a--
pUnit:FullCastSpellOnTarget(17174,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11686', 3325, 1)
end

function spell1_11686(pUnit, Event) --@Net,n/a--
pUnit:FullCastSpellOnTarget(6533,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11686', 2295, 1)
end

function spell2_11686(pUnit, Event) --@Shoot,n/a--
pUnit:FullCastSpellOnTarget(6660,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11686', 643, 1)
end

function Sorts_11686(pUnit, Event)
local choix_sorts_11686 = math.random(0, 2)
if choix_sorts_11686 == 0 then
pUnit:RegisterEvent('spell0_11686', 1, 1)
end
if choix_sorts_11686 == 1 then
pUnit:RegisterEvent('spell1_11686', 1, 1)
end
if choix_sorts_11686 == 2 then
pUnit:RegisterEvent('spell2_11686', 1, 1)
end
end

function mob11686_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_11686', math.random(1500, 3000), 1)
end

function mob11686_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob11686_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob11686_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(11686, 1, 'mob11686_Action')
RegisterUnitEvent(11686, 2, 'mob11686_Leave')
RegisterUnitEvent(11686, 3, 'mob11686_Kill')
RegisterUnitEvent(11686, 4, 'mob11686_Die')
